<?xml version="1.0" encoding="utf-8"?>
<xs:schema id="dsKpoFind" targetNamespace="http://tempuri.org/dsKpoFind.xsd" xmlns:mstns="http://tempuri.org/dsKpoFind.xsd" xmlns="http://tempuri.org/dsKpoFind.xsd" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata" xmlns:msprop="urn:schemas-microsoft-com:xml-msprop" attributeFormDefault="qualified" elementFormDefault="qualified">
  <xs:annotation>
    <xs:appinfo source="urn:schemas-microsoft-com:xml-msdatasource">
      <DataSource DefaultConnectionIndex="0" FunctionsComponentName="QueriesTableAdapter" Modifier="AutoLayout, AnsiClass, Class, Public" SchemaSerializationMode="IncludeSchema" xmlns="urn:schemas-microsoft-com:xml-msdatasource">
        <Connections>
          <Connection AppSettingsObjectName="Settings" AppSettingsPropertyName="p301ConnString" ConnectionStringObject="" IsAppSettingsProperty="True" Modifier="Assembly" Name="p301ConnString (Settings)" ParameterPrefix="@" PropertyReference="ApplicationSettings.p301.Properties.Settings.GlobalReference.Default.p301ConnString" Provider="System.Data.SqlClient">
          </Connection>
        </Connections>
        <Tables>
          <TableAdapter BaseClass="System.ComponentModel.Component" DataAccessorModifier="AutoLayout, AnsiClass, Class, Public" DataAccessorName="taKpoFind" GeneratorDataComponentClassName="taKpoFind" Name="dtKpoFind" UserDataComponentName="taKpoFind">
            <MainSource>
              <DbSource ConnectionRef="p301ConnString (Settings)" DbObjectType="Unknown" FillMethodModifier="Public" FillMethodName="Fill" GenerateMethods="Fill" GenerateShortCommands="False" GeneratorSourceName="Fill" QueryType="Rowset" ScalarCallRetval="System.Object, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" UseOptimisticConcurrency="False" UserGetMethodName="GetData" UserSourceName="Fill">
                <SelectCommand>
                  <DbCommand CommandType="Text" ModifiedByUser="True">
                    <CommandText>SELECT     TOP (@pTOP) vKpo.NPP_KPO, vKpo.K_KPO, vKpo.NPP_KPOyear, vUks.NPP_UKSyear, vKpo.N_FIO, vKpo.D_OBRASCH, vKpo.D_KONS, vKpo.V_KONS, 
                      vKpo.V_OBRASCH, vKpo.K_UKS, dbo.CompressFio(s_rab_spec.N_RAB) AS N_SPEC, dbo.CompressFio(s_rab.N_RAB) AS N_RAB
FROM         vKpo LEFT OUTER JOIN
                      s_rab ON vKpo.K_RAB = s_rab.K_RAB LEFT OUTER JOIN
                      s_rab AS s_rab_spec ON vKpo.K_SPEC = s_rab_spec.K_RAB LEFT OUTER JOIN
                      b_adr ON vKpo.K_ADR = b_adr.K_ADR LEFT OUTER JOIN
                      vUks ON vKpo.K_UKS = vUks.K_UKS
GROUP BY vKpo.NPP_KPO, vKpo.K_KPO, vUks.NPP_UKS, vKpo.D_OBRASCH, vUks.D_DZ, vKpo.N_FIO, vKpo.D_KONS, vKpo.V_KONS, vKpo.V_OBRASCH, 
                      vKpo.D_OBRASCH, vKpo.K_UKS, s_rab_spec.N_RAB, s_rab.N_RAB, vKpo.NPP_KPOyear, vUks.NPP_UKSyear
ORDER BY vKpo.D_OBRASCH</CommandText>
                    <Parameters>
                      <Parameter AllowDbNull="False" AutogeneratedName="pTOP" ColumnName="" DataSourceName="" DataTypeServer="unknown" DbType="Int32" Direction="Input" ParameterName="@pTOP" Precision="0" Scale="0" Size="0" SourceColumn="" SourceColumnNullMapping="False" SourceVersion="Current">
                      </Parameter>
                    </Parameters>
                  </DbCommand>
                </SelectCommand>
              </DbSource>
            </MainSource>
            <Mappings>
              <Mapping SourceColumn="NPP_KPO" DataSetColumn="NPP_KPO" />
              <Mapping SourceColumn="K_KPO" DataSetColumn="K_KPO" />
              <Mapping SourceColumn="NPP_KPOyear" DataSetColumn="NPP_KPOyear" />
              <Mapping SourceColumn="N_FIO" DataSetColumn="N_FIO" />
              <Mapping SourceColumn="D_OBRASCH" DataSetColumn="D_OBRASCH" />
              <Mapping SourceColumn="D_KONS" DataSetColumn="D_KONS" />
              <Mapping SourceColumn="V_KONS" DataSetColumn="V_KONS" />
              <Mapping SourceColumn="V_OBRASCH" DataSetColumn="V_OBRASCH" />
              <Mapping SourceColumn="K_UKS" DataSetColumn="K_UKS" />
              <Mapping SourceColumn="N_SPEC" DataSetColumn="N_SPEC" />
              <Mapping SourceColumn="N_RAB" DataSetColumn="N_RAB" />
              <Mapping SourceColumn="NPP_UKSyear" DataSetColumn="NPP_UKSyear" />
            </Mappings>
            <Sources>
            </Sources>
          </TableAdapter>
        </Tables>
        <Sources>
        </Sources>
      </DataSource>
    </xs:appinfo>
  </xs:annotation>
  <xs:element name="dsKpoFind" msdata:IsDataSet="true" msdata:UseCurrentLocale="true" msprop:Generator_UserDSName="dsKpoFind" msprop:Generator_DataSetName="dsKpoFind">
    <xs:complexType>
      <xs:choice minOccurs="0" maxOccurs="unbounded">
        <xs:element name="dtKpoFind" msprop:Generator_UserTableName="dtKpoFind" msprop:Generator_RowDeletedName="dtKpoFindRowDeleted" msprop:Generator_RowChangedName="dtKpoFindRowChanged" msprop:Generator_RowClassName="dtKpoFindRow" msprop:Generator_RowChangingName="dtKpoFindRowChanging" msprop:Generator_RowEvArgName="dtKpoFindRowChangeEvent" msprop:Generator_RowEvHandlerName="dtKpoFindRowChangeEventHandler" msprop:Generator_TableClassName="dtKpoFindDataTable" msprop:Generator_TableVarName="tabledtKpoFind" msprop:Generator_RowDeletingName="dtKpoFindRowDeleting" msprop:Generator_TablePropName="dtKpoFind">
          <xs:complexType>
            <xs:sequence>
              <xs:element name="NPP_KPO" msdata:ReadOnly="true" msprop:Generator_UserColumnName="NPP_KPO" msprop:Generator_ColumnVarNameInTable="columnNPP_KPO" msprop:Generator_ColumnPropNameInRow="NPP_KPO" msprop:Generator_ColumnPropNameInTable="NPP_KPOColumn" type="xs:int" minOccurs="0" />
              <xs:element name="K_KPO" msdata:ReadOnly="true" msdata:AutoIncrement="true" msprop:Generator_UserColumnName="K_KPO" msprop:Generator_ColumnVarNameInTable="columnK_KPO" msprop:Generator_ColumnPropNameInRow="K_KPO" msprop:Generator_ColumnPropNameInTable="K_KPOColumn" type="xs:int" />
              <xs:element name="NPP_KPOyear" msdata:ReadOnly="true" msprop:Generator_UserColumnName="NPP_KPOyear" msprop:Generator_ColumnVarNameInTable="columnNPP_KPOyear" msprop:Generator_ColumnPropNameInRow="NPP_KPOyear" msprop:Generator_ColumnPropNameInTable="NPP_KPOyearColumn" minOccurs="0">
                <xs:simpleType>
                  <xs:restriction base="xs:string">
                    <xs:maxLength value="23" />
                  </xs:restriction>
                </xs:simpleType>
              </xs:element>
              <xs:element name="N_FIO" msdata:ReadOnly="true" msprop:Generator_UserColumnName="N_FIO" msprop:Generator_ColumnVarNameInTable="columnN_FIO" msprop:Generator_ColumnPropNameInRow="N_FIO" msprop:Generator_ColumnPropNameInTable="N_FIOColumn" minOccurs="0">
                <xs:simpleType>
                  <xs:restriction base="xs:string">
                    <xs:maxLength value="155" />
                  </xs:restriction>
                </xs:simpleType>
              </xs:element>
              <xs:element name="D_OBRASCH" msdata:ReadOnly="true" msprop:Generator_UserColumnName="D_OBRASCH" msprop:Generator_ColumnVarNameInTable="columnD_OBRASCH" msprop:Generator_ColumnPropNameInRow="D_OBRASCH" msprop:Generator_ColumnPropNameInTable="D_OBRASCHColumn" type="xs:dateTime" minOccurs="0" />
              <xs:element name="D_KONS" msdata:ReadOnly="true" msprop:Generator_UserColumnName="D_KONS" msprop:Generator_ColumnVarNameInTable="columnD_KONS" msprop:Generator_ColumnPropNameInRow="D_KONS" msprop:Generator_ColumnPropNameInTable="D_KONSColumn" type="xs:dateTime" minOccurs="0" />
              <xs:element name="V_KONS" msdata:ReadOnly="true" msprop:Generator_UserColumnName="V_KONS" msprop:Generator_ColumnVarNameInTable="columnV_KONS" msprop:Generator_ColumnPropNameInRow="V_KONS" msprop:Generator_ColumnPropNameInTable="V_KONSColumn" type="xs:dateTime" minOccurs="0" />
              <xs:element name="V_OBRASCH" msdata:ReadOnly="true" msprop:Generator_UserColumnName="V_OBRASCH" msprop:Generator_ColumnVarNameInTable="columnV_OBRASCH" msprop:Generator_ColumnPropNameInRow="V_OBRASCH" msprop:Generator_ColumnPropNameInTable="V_OBRASCHColumn" type="xs:dateTime" minOccurs="0" />
              <xs:element name="K_UKS" msprop:Generator_UserColumnName="K_UKS" msprop:Generator_ColumnVarNameInTable="columnK_UKS" msprop:Generator_ColumnPropNameInRow="K_UKS" msprop:Generator_ColumnPropNameInTable="K_UKSColumn" type="xs:int" minOccurs="0" />
              <xs:element name="N_SPEC" msdata:ReadOnly="true" msprop:Generator_UserColumnName="N_SPEC" msprop:Generator_ColumnVarNameInTable="columnN_SPEC" msprop:Generator_ColumnPropNameInRow="N_SPEC" msprop:Generator_ColumnPropNameInTable="N_SPECColumn" minOccurs="0">
                <xs:simpleType>
                  <xs:restriction base="xs:string">
                    <xs:maxLength value="1024" />
                  </xs:restriction>
                </xs:simpleType>
              </xs:element>
              <xs:element name="N_RAB" msdata:ReadOnly="true" msprop:Generator_UserColumnName="N_RAB" msprop:Generator_ColumnPropNameInRow="N_RAB" msprop:Generator_ColumnVarNameInTable="columnN_RAB" msprop:Generator_ColumnPropNameInTable="N_RABColumn" minOccurs="0">
                <xs:simpleType>
                  <xs:restriction base="xs:string">
                    <xs:maxLength value="1024" />
                  </xs:restriction>
                </xs:simpleType>
              </xs:element>
              <xs:element name="NPP_UKSyear" msprop:Generator_UserColumnName="NPP_UKSyear" msprop:Generator_ColumnPropNameInRow="NPP_UKSyear" msprop:Generator_ColumnVarNameInTable="columnNPP_UKSyear" msprop:Generator_ColumnPropNameInTable="NPP_UKSyearColumn" minOccurs="0">
                <xs:simpleType>
                  <xs:restriction base="xs:string">
                    <xs:maxLength value="23" />
                  </xs:restriction>
                </xs:simpleType>
              </xs:element>
            </xs:sequence>
          </xs:complexType>
        </xs:element>
      </xs:choice>
    </xs:complexType>
    <xs:unique name="Constraint1" msdata:PrimaryKey="true">
      <xs:selector xpath=".//mstns:dtKpoFind" />
      <xs:field xpath="mstns:K_KPO" />
    </xs:unique>
  </xs:element>
</xs:schema>